/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package pkginterface;

/**
 *
 * @author sara
 */
public class Circle implements Graph{
    private int r;

    public Circle(int r) {
        this.r = r;
    }
    public int getArea()
    {
        return (int) (3.1415926*r*r);
    }
    public int getPerimeter()
    {
        return (int) (2*3.1415926*r);
    }
    public String toString()
    {
        return "Circle{" + "r="+ r+ '}' + "\narea:"+this.getArea()+"\ncircum:"+this.getPerimeter() ;
    }
}
